<?php
/**
 * PDF reporting class
 *
 * This class contains all methods needed to output
 * a PDF report.
 * @package Reports
 */

/**
 *
 */
require_once(AD_SERVER_PATH . '/reports/report.php');

/**
 * PDF reporting class
 *
 * This class contains all methods needed to output
 * a PDF report.
 * @package Reporting
 */
class CPDF_report extends CReport
{
	/**
	 * Set cell cordinates
	 *
	 * Sets the cordinates for the next displayed cell.
	 * @param int $x
	 * @param int $y
	 */
	protected function set_cords($x, $y)
	{
		if (is_numeric($y))
		{
			$this->pdf->SetY($y);
		}
		if (is_numeric($x))
		{
			$this->pdf->SetX($x);
		}
	}

	/**
	 * Test case
	 *
	 * Outputs simple PDF for testing.
	 */
	public function test()
	{
		$pdf = new FPDF();
		$pdf->AddPage();
		$pdf->SetFont('Arial', 'B', 16);
		$pdf->Cell(40, 10, 'Hello World!');
		$pdf->Output();
	}
}
